def agepts():
    age = int(raw_input("Input age: "))
    if 21 <= age <= 44:
        print 10
        return 10
    elif age > 44:
        num = age - 44
        pts = 10
        for i in range(num):
            pts = pts - 2
        if pts < 0:
            pts = 0
        print pts
        return pts
    elif age < 21:
        num = 21 - age
        pts = 10
        for i in range (num):
            pts = pts - 2
        if pts < 0:
            pts = 0
        print pts
        return pts

def edu():
    yrs = int(raw_input("Input education years: "))
    if yrs > 12:
        yrs = 12
    print yrs
    return yrs

def postsec():
    yrs = int(raw_input("Input Post-Secondary years: "))
    if yrs > 10:
        yrs = 10
    print yrs
    return yrs

def workxp():
    yrs = int(raw_input("Input work experience years: "))
    if yrs > 8:
        yrs = 8
    print yrs
    return yrs

def arrangedjob():
    arranged = 'x'
    while arranged.lower() != 'y' and arranged.lower() != 'n':
        arranged = raw_input("Arranged employment? Y/N ")
    if arranged.lower() == 'y':
        print 10
        return 10
    elif arranged.lower() == 'n':
        print 0
        return 0

def occupation():
    occ = int(raw_input("occupation value: "))
    if occ > 10:
        occ = 10
    print occ
    return occ

def language():
    lang = 'x'
    while lang.lower() != 'e' and lang.lower() != 'f':
        lang = raw_input("Primary Lang: F/E ")
    if lang == 'e':
        engpts = int(raw_input("How well do you speak English? 0/10 "))
        frpts  = int(raw_input("How well do you speak French? 0/5 "))
        if (engpts + frpts) > 15:
            print 15
            return 15
        print engpts + frpts
        return engpts + frpts
    elif lang == 'f':
        engpts = int(raw_input("How well do you speak English? 0/2 "))
        frpts  = int(raw_input("How well do you speak French? 0/13 "))
        if (engpts + frpts) > 15:
            print 15
            return 15
        print engpts + frpts
        return engpts + frpts

def relatives():
    relpts = int(raw_input("How many pts for relatives? "))
    if relpts > 15:
        relpts = 15
    print relpts
    return relpts

def suit():
    suit = int(raw_input("How many points for suitability? "))
    if suit > 10:
        suit = 10
    print suit
    return suit

def needpts():
    numpts = int(raw_input("How many points do they need? 25,50 "))
    return numpts

def addpts(ptsneed):
    totalpts = agepts() + edu() + postsec() + workxp() + arrangedjob() + \
               occupation() + language() + relatives() + suit()
    if totalpts >= ptsneed:
        print totalpts, "/", ptsneed
        return "Accepted"
    else:
        print totalpts, "/", ptsneed
        return "Denied"

goAgain = 'y'
while goAgain.lower() == 'y':
    goAgain = 'x'
    name = raw_input("Name: ")
    ptsneed = needpts()
    print addpts(ptsneed)
    while goAgain.lower() != 'y' and goAgain.lower() != 'n':
        goAgain = raw_input("Would you like to go again? ")
    print
